home
***
CD-ROM
|
disk
|
FTP
|
other
***
search
/
TPUG - Toronto PET Users Group
/
TPUG Users Group CD
/
TPUG Users Group CD.iso
/
C64
/
X-Demos and Utilities
/
(c)x2.d64
/
spredit.c
(
.txt
)
< prev
next >
Wrap
Commodore BASIC
|
2007-02-04
|
1KB
|
40 lines
10 V=53248:POKEV+32,254:POKEV+27,3:POKEV,24:POKEV+1,50:POKE2040,11
20 FORI=704TO766:POKEI,0:NEXT:POKEV+21,3:FORI=704TO726STEP3:POKEI,255:NEXT
30 D$="------------------------":GOSUB60000:X=24:Y=50:F=255
40 C$=" BFCXYDSLO"
50 POKE2041,13:FORI=832TO894:POKEI,0:NEXT:POKEV+2,255:POKEV+3,200
60 POKEV+23,2:POKEV+29,2:POKEV+40,3
100 GETA$:IFA$=""THEN100
110 IFA$="[145]"ANDR>0THENR=R-1:Y=Y-8:POKEV+1,Y:GOTO100
120 IFA$=""ANDR<20THENR=R+1:Y=Y+8:POKEV+1,Y:GOTO100
130 IFA$="[157]"ANDC>0THENC=C-1:X=X-8:POKEV,X:GOTO100
140 IFA$=""ANDC<23THENC=C+1:X=X+8:POKEV,X:GOTO100
150 IFA$=""ORA$="[147]"THENC=0:R=0:X=24:Y=50:POKEV,X:POKEV+1,Y:GOTO100
160 FORI=1TOLEN(C$):IFA$=MID$(C$,I,1)THENA=I:I=LEN(C$)
170 NEXT:IFA=0THEN100
180 ONAGOTO200,300,310,320,330,340,350
200 B=R*3+INT(C/8):BIT=2^(7-(C-(INT(C/8)*8)))
210 IF PEEK(832+B)ANDBITTHENPOKE832+B,PEEK(832+B)-BIT:GOTO230
220 POKE832+B,PEEK(832+B)+(BIT)
230 SC=1024+C+(40*R):IFPEEK(SC)=81THENPOKESC,45:GOTO100
240 POKESC,81:GOTO100
300 D$="[144]------------------------":FORI=832TO894:POKEI,0:NEXT:GOSUB60000:GOTO100
310 D$="[144][209][209][209][209][209][209][209][209][209][209][209][209][209][209][209][209][209][209][209][209][209][209][209][209]":FORI=832TO894:POKEI,F:NEXT:GOSUB60000:GOTO100
320 POKEV+40,PEEK(V+40)+1AND7:GOTO100
330 POKEV+29,PEEK(V+29)+2AND(2):GOTO100
340 POKEV+23,PEEK(V+23)+2AND(2):GOTO100
350 L=60000:J=0:PRINT"[147]":FORI=832TO894
360 IFJ=0THENPRINTL"DATA";:J=J+1:L=L+10
370 PRINTPEEK(I)"[157],";:J=J+1:IFJ=9THENPRINT"[157] ":J=0
380 NEXT:POKEV+21,0:NEW
60000 PRINT"[144][147]";:FORI=1TO21:PRINTD$:NEXT
60010 PRINT""TAB(27)"B BLANK
60020 [153][163]27)"F FILL
60030 PRINTTAB(27)"C COLOUR"
60040 PRINTTAB(27)"X SCALE X
60050 [153][163]27)"Y SCALE Y
60060 REMPRINTTAB(27)"S SAVE
60070 [143]PRINTTAB(27)"L LOAD
60080 PRINTTAB(27)"D DATA
60090 [142]